package com.aaa.boot.config;

import lombok.Getter;

/**
 * @author MK
 * @version 1.0
 * 创建时间：2025/3/20 19:00
 */
@Getter
public class BusinessException extends RuntimeException {
    private int code;

    public BusinessException(int code, String message) {
        super(message);
        this.code = code;
    }

    // 快速构建方法
    public static BusinessException error(int code, String msg) {

        return new BusinessException(code, msg);
    }

}
